package core;
import ibm.widgets.ObjectFactory;
import ibm.widgets.WButton;
import ibm.widgets.WLink;
import ibm.widgets.WListBox;
import ibm.widgets.WStaticText;
import ibm.widgets.WTextField;
import resources.core.ControlsMappingHelper;
import appobjects.CommonParent;
import appobjects.NameSpaceArea;
import appobjects.WaitPrompt;
import appobjects.WebSphereLogIn;
import appobjects.OpportunitiesBaseDataView.Cognos.CommonParts;
import appobjects.OpportunitiesBaseDataView.WebSphere.ManualUpdateView;
import core.controls.Button;
import core.controls.Image;
import core.controls.Link;
import core.controls.SelectBox;
import core.controls.StaticText;
import core.controls.Table;
import core.controls.TextField;
/**
 * Description   : Functional Test Script
 * @author angel.tsvetkov
 */
public class ControlsMapping extends ControlsMappingHelper
{
	private static NameSpaceArea namespaceParent = null;
	private static WebSphereLogIn webSphereLogIn = null;
	private static CommonParent commonParent = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.GeographyFilter geographyFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.ProductFilter productFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.SellerFilter sellerFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.TimePeriodFilter timePeriodFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.CustomerFilter customerFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.OpportunityFilter opportunityFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.RevenueFilter revenueFilter = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.CommonParts commonFilterElements = null;
	private static appobjects.OpportunitiesBaseDataView.Cognos.MainView mainViewTable = null;
	private static appobjects.OpportunitiesBaseDataView.WebSphere.ManualUpdateView manualUpdate = null;
	private static appobjects.WaitPrompt waitPrompt = null;

	
	static{
		namespaceParent = new appobjects.NameSpaceArea();
		
		webSphereLogIn = new WebSphereLogIn();

		commonParent = new CommonParent();
		
		geographyFilter = new appobjects.OpportunitiesBaseDataView.Cognos.GeographyFilter();
		
		productFilter = new appobjects.OpportunitiesBaseDataView.Cognos.ProductFilter();
		
		sellerFilter = new appobjects.OpportunitiesBaseDataView.Cognos.SellerFilter();
		
		timePeriodFilter = new appobjects.OpportunitiesBaseDataView.Cognos.TimePeriodFilter();
		
		customerFilter = new appobjects.OpportunitiesBaseDataView.Cognos.CustomerFilter();
		
		opportunityFilter = new appobjects.OpportunitiesBaseDataView.Cognos.OpportunityFilter();
		
		revenueFilter = new appobjects.OpportunitiesBaseDataView.Cognos.RevenueFilter();
		
		mainViewTable = new appobjects.OpportunitiesBaseDataView.Cognos.MainView();
		
		commonFilterElements = new CommonParts();
		
		manualUpdate = new appobjects.OpportunitiesBaseDataView.WebSphere.ManualUpdateView();
		
		waitPrompt = new WaitPrompt();
	}
	
	public static class ChooseNamespace
	{
		public static final SelectBox namespace_dropdown = new SelectBox("CAMNamespace",".name",ObjectFactory.gsHtmlLBClass,namespaceParent.get(),"Namespace drop-down");
	
		public static final core.controls.Button ok_button = new core.controls.Button("cmdOK",".id",WButton.gsHtmlSubmitButtonClass,namespaceParent.get(),"OK button");
	
		public static final core.controls.Button cancel_button = new core.controls.Button("cmdCancel",".id",WButton.gsHtmlButtonClass,namespaceParent.get(),"Cancel button");
	}
	
	public static class LoginFormCognos 
	{
		public static final TextField username_textbox = new TextField("CAMUsername",".name",WTextField.gsHtmlDefaultTFClass,namespaceParent.get(),"Username textbox");
	
		public static final TextField password_textbox = new TextField("CAMPassword",".name",WTextField.gsHtmlDefaultPWClass,namespaceParent.get(),"Password textbox");
	}
	
	public static class LogInFormWebSphere
	{
		public static final TextField username_textbox = new TextField("userName",".id",WTextField.gsHtmlDefaultTFClass,webSphereLogIn.get(),"Username textbox");
		
		public static final TextField password_textbox = new TextField("password",".id",WTextField.gsHtmlDefaultPWClass,webSphereLogIn.get(),"Password textbox");
		
		public static final Button submit_button = new Button("ibm-login",".id","Html.INPUT.submit",webSphereLogIn.get(),"Password textbox");
	}
	
	public static class PromptPageButtons
	{
		public static final Button cancel_button = new Button("cancel", ".id", "Html.BUTTON", commonParent.get(), "Cancel button");
		
		public static final Button refresh_button = new Button("reprompt", ".id", "Html.BUTTON", commonParent.get(), "Refresh button");
		
		public static final Button finish_button = new Button("finish", ".id", "Html.BUTTON", commonParent.get(), "Finish button");
	}
	
	public static class FilterCommonElements
	{
		public static final Button GO_button = new Button("finish",".id","Html.BUTTON",commonFilterElements.getFilterCommonArea(), "GO button");
		
		public static final Button Cancel_button = new Button("cancel",".id","Html.BUTTON",commonFilterElements.getFilterCommonArea(), "Cancel button");
	
		public static final Link showAll_link = new Link("showAllLink",".id",WLink.gsHtmlDefaultClass,commonFilterElements.getFilterCommonArea(), "Show All hyperlink");
	
		public static final Link hideAll_link = new Link("hideAllLink",".id",WLink.gsHtmlDefaultClass,commonFilterElements.getFilterCommonArea(), "Hide All hyperlink");
	}
	
	public static class GeographyFilter
	{
		public static final SelectBox IOT_listbox = new SelectBox(geographyFilter.getIOTListBox(), "IOT select box");
		
		public static final SelectBox IMT_listbox = new SelectBox(geographyFilter.getIMTListBox(), "IMT select box");
		
		public static final SelectBox GMR_listbox = new SelectBox(geographyFilter.getGMRListBox(), "GMR select box");
		
		public static final SelectBox Country_listbox = new SelectBox(geographyFilter.getCountryListBox(), "Country select box");
	}
	
	public static class SellerFilter
	{
		public static final SelectBox TerritoryType_listbox = new SelectBox(sellerFilter.getTerritoryTypeListBox(), "Territory Type select box");
		
		public static final SelectBox Role_listbox = new SelectBox(sellerFilter.getRoleListBox(), "Role List box");
		
		public static final SelectBox SellerName_listbox = new SelectBox(sellerFilter.getSellerNameListBox(), "Seller Name select box");
	}
	
	public static class TimePeriodFilter
	{
		public static final SelectBox SetRangeOfTimePeriods_listbox = new SelectBox(timePeriodFilter.getSetRangeOfTimePeriodListBox(), "Set Range of Time Periods select box");
		
		public static final SelectBox CreateDateTimePeriod_listbox = new SelectBox(timePeriodFilter.getCreatedDateTimePeriodListBox(), "Create Date - Time Period select box");
		
		public static final SelectBox CreateDateYear_listbox = new SelectBox(timePeriodFilter.getCreatedDateYearListBox(), "Create Date - Year select box");
		
		public static final SelectBox AcceptanceDateTimePeriod_listbox = new SelectBox(timePeriodFilter.getAcceptedDateTimePeriodListBox(), "Acceptance Date - Time Period select box");
		
		public static final SelectBox AcceptanceDateYear_listbox = new SelectBox(timePeriodFilter.getAcceptedDateYearListBox(), "Acceptance Date - Year select box");
		
		public static final SelectBox ForecastDateTimePeriod_listbox = new SelectBox(timePeriodFilter.getForecastDateTimePeriodListBox(), "Forecast Date - Time Period select box");
		
		public static final SelectBox ForecastDateYear_listbox = new SelectBox(timePeriodFilter.getForecastDateYearListBox(), "Forecast Date - Year select box");
		
		public static final SelectBox DecisionDateTimePeriod_listbox = new SelectBox(timePeriodFilter.getDecisionDateTimePeriodListBox(), "Decision Date - Time Period select box");
		
		public static final SelectBox DecisionDateYear_listbox = new SelectBox(timePeriodFilter.getDecisionDateYearListBox(), "Decision Date - Year select box");
	}
	
	public static class ProductFilter
	{
		public static final SelectBox BrandOfferingType_listbox = new SelectBox(productFilter.getBrandOfferingTypeListBox(), "Brand Offering Type select box");
		
		public static final SelectBox SubBrandSPL_listbox = new SelectBox(productFilter.getSubBrandSPLListBox(), "Sub Brand / SPL select box");
		
		public static final SelectBox Product_listbox = new SelectBox(productFilter.getProductListBox(), "Product select box");
		
		public static final SelectBox Cose_listbox = new SelectBox(productFilter.getCoseListBox(), "Cose select box");
		
		public static final SelectBox LessComplexProduct_listbox = new SelectBox(productFilter.getLessComplexProductListBox(), "Less Complex product select box");
		
		public static final SelectBox SMILE_listbox = new SelectBox(productFilter.getSMILEListBox(), "SMILE select box");
		
		public static final SelectBox SEI_listbox = new SelectBox(productFilter.getSEIListBox(), "SEI select box");
		
		public static final SelectBox BCRSRenewals_listbox = new SelectBox(productFilter.getBCRSRenewalsListBox(), "BCRS Renewals select box");
		
		public static final SelectBox DNSO_listbox = new SelectBox(productFilter.getDNSOListBox(), "DNSO select box");
		
		public static final SelectBox SmallDeals_listbox = new SelectBox(productFilter.getSmallDealsListBox(), "Small Deals select box");
		
		public static final SelectBox Top25OfferingITS_listbox = new SelectBox(productFilter.getTop25OfferingsITSListBox(), "Top 25 Offering ITS select box");
		
		public static final SelectBox Top30Offering_listbox = new SelectBox(productFilter.getTop30OfferingsListBox(), "Top 30 Offering select box");
		
		public static final Button updateFilter_button = new Button(productFilter.getUpdateFilterButton(), "Update Filter Button");
	}
	
	public static class CustomerFilter
	{
		public static final SelectBox Sector_listbox = new SelectBox(customerFilter.getSectorsListBox(), "Sector select box");
		
		public static final SelectBox Industry_listbox = new SelectBox(customerFilter.getIndustryListBox(), "Industry select box");
		
		public static final SelectBox ClientName_listbox = new SelectBox(customerFilter.getClientNameListBox(), "Client Name select box");
		
		public static final SelectBox ClientID_listbox = new SelectBox(customerFilter.getClientIDListBox(), "Client ID select box");
		
		public static final SelectBox CustomerName_listbox = new SelectBox(customerFilter.getCustomerNameListBox(), "Customer Name select box");
		
		public static final SelectBox CustomerNumber_listbox = new SelectBox(customerFilter.getCustomerNumberListBox(), "Customer Number select box");
		
		public static final SelectBox CoverageName_listbox = new SelectBox(customerFilter.getCoverageNameListBox(), "Coverage Name select box");
		
		public static final SelectBox CoverageID_listbox = new SelectBox(customerFilter.getCoverageIDListBox(), "Coverage ID select box");
	}
	
	public static class OpportunityFilter
	{
		public static final SelectBox Territory_listbox = new SelectBox(opportunityFilter.getTerritoryListBox(), "Territory select box");
		
		public static final SelectBox InsideSalesInvolved_listbox = new SelectBox(opportunityFilter.getInsideSalesInvolvedListBox(), "Inside Sales Involved select box");
		
		public static final SelectBox SalesStageGroup_listbox = new SelectBox(opportunityFilter.getSalesStageGroupListBox(), "Sales Stage Group select box");
		
		public static final SelectBox OwningOrg_listbox = new SelectBox(opportunityFilter.getOwningOrgListBox(), "Owning Org select box");
		
		public static final SelectBox OpptyRole_listbox = new SelectBox(opportunityFilter.getOpptyRoleListBox(), "Oppty Role select box");
		
		public static final SelectBox OpptySource_listbox = new SelectBox(opportunityFilter.getOpptySourceListBox(), "Oppty Source select box");
		
		public static final SelectBox PipelineAgeRange_listbox = new SelectBox(opportunityFilter.getPipelineAgeRangeListBox(), "Pipeline Age Range select box");
		
		public static final SelectBox StuckPipeline_listbox = new SelectBox(opportunityFilter.getStuckPipelineListBox(), "Stuck Pipeline select box");
		
		public static final SelectBox DuplicateOppty_listbox = new SelectBox(opportunityFilter.getDuplicateOpptyListBox(), "Duplivate Oppty select box");
	}
	
	public static class RevenueFilter
	{
		public static final SelectBox OpportunityRevenue_listbox = new SelectBox(revenueFilter.getOpportunityRevenueListBox(),"Opportunity Revenue select box");
		
		public static final SelectBox TotalOpportunityValue_listbox = new SelectBox(revenueFilter.getTotalOpportunityValueListBox(),"Total Opportunity Value select box");
	}
	
	public static class LoadingCheck
	{
		public static final Image wait_image = new Image(waitPrompt.get(), "Wait image");
	}
	
	public static class MainView
	{
		public static final Table mainView_table = new Table(mainViewTable.get(), "Main View Table");
	}
	
	public static class ManualUpdateView
	{
		public static class ContextualDataArea
		{
			public static final StaticText opportunityName_staticText = new StaticText("elOpportunityName", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Opportunity Name value");
			
			public static final StaticText detailKey_staticText = new StaticText("elDetailKey", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Detail Key value");
			
			public static final StaticText sellerName_staticText = new StaticText("elSellerName", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Seller Name value");
			
			public static final StaticText salesStageNoAndName_staticText = new StaticText("elSalesStageNoAndName", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Sales Stage No And Name value");
			
			public static final StaticText customerName_staticText = new StaticText("elCustomerName", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Customer Name value");
			
			public static final StaticText customerNumber_staticText = new StaticText("elCustomerNumber", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Customer number value");
			
			public static final StaticText oppTotalVal_staticText = new StaticText("elOpportunityValue", ".id", "Html.SPAN", manualUpdate.getContextualDataParent(),"Total Value");
		}
		
		public static class DropDownsArea
		{
			public static final StaticText repInput_staticText = new StaticText("elRepInput", ".id", "Html.SPAN", manualUpdate.getDropDownsParent(), "Rep Input label");
			
			public static final SelectBox primaryChannel_selectBox = new SelectBox("selPrimaryChannel", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Primary Channel select box");
		
			public static final SelectBox customerFacing_selectBox = new SelectBox("selCustomerFacing", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Customer Facing select box");
			
			public static final SelectBox buildAhead_selectBox = new SelectBox("selBuildAheadIndicator", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Build Ahead select box");
			
			public static final SelectBox duplicateOpportunity_selectBox = new SelectBox("selDuplicateOpportunity", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Duplicate Opportunity select box");
		
			public static final TextField expectedCloseDate_textField = new TextField("elExpectedCloseDateContainer", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "Expected Close Date text box");
		
			public static final TextField expectedCloseQuarter_textField = new TextField("txtExpectedCloseQuarter", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "Expected Close Quarter text box");
			
			public static final TextField poNumber_textField = new TextField("txtPoNumber", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "PO Number text box");
			
			public static final SelectBox routeToMarket_selectBox = new SelectBox("selRouteToMarket", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Route To Market select box");
			
			public static final SelectBox bpRole_selectBox = new SelectBox("selBpRole", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "BP Role select box");
			
			public static final SelectBox status_selectBox = new SelectBox("selStatus", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Status select box");
			
			public static final SelectBox lostAnalysis_selectBox = new SelectBox("selLostAnalysis", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Lost Analysis select box");
			
			public static final SelectBox delegateSeller_selectBox = new SelectBox("selDelegateSellerName", ".id", WListBox.gsHtmlDefaultClass, manualUpdate.getDropDownsParent(), "Delegate Seller select box");
			
			public static final TextField expectedCloseWeek_textField = new TextField("txtExpectedCloseWeek", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "Expected Close Week text box");
			
			public static final TextField iBSSRevenue_textField = new TextField("txtIbssRevenueKUSD", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "iBSS Revenue text box");
			
			public static final TextField nextActionDate_textField = new TextField("elNextActionDateContainer", ".id", WTextField.gsHtmlDefaultTFClass, manualUpdate.getDropDownsParent(), "Next Action Date text box");
		}
	}	
}

